export const option = function () {
  return {
    refreshBtn: true,
    columnBtn: true,
    border: true,
    stripe: true,
    index: true,
    editBtn: true,
    delBtn: true,
    align: 'center',
    addBtn: !['view'].includes(this.type),
    menu: !['view'].includes(this.type),
    labelWidth: 140,
    indexLabel: '序号',
    column: [
      {
        label: '主要原料名称',
        prop: 'mainMaterialA',
        rules: [
          {
            required: true,
            message: '请输入主要原料名称',
            trigger: 'blur'
          }
        ],
        minWidth: 150
      },
      {
        label: '年采购量',
        prop: 'purchaseVolumeA',
        rules: [
          {
            required: true,
            message: '请输入年采购量',
            trigger: 'blur'
          }
        ],
        minWidth: 100
      },
      {
        label: '供应商',
        prop: 'materialSupplierA',
        minWidth: 150
      },
      {
        label: '合作年限',
        prop: 'cooperationYearsA',
        minWidth: 80
      }
    ]
  }
}